package com.yellow.dispatchservice.controller;

import com.yellow.dispatchservice.service.RoutePlanService;
import jakarta.annotation.Resource;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;

/**
 * @author: hy
 * @create: 2024-04-23
 */
@RestController
@Slf4j
@CrossOrigin(origins = "*", maxAge = 3600)
@RequestMapping("/routePlan")
public class RoutePlanController {

    @Resource
    private RoutePlanService routePlanService;
    @GetMapping("/getDesByOrderId/{id}")
    public String getDestinationByOrderId(@PathVariable(value = "id") Integer orderId){
        return routePlanService.getDestinationByOrderId(orderId);
    }
}
